#include "Material.hpp"

#include "Exception.hpp"
#include "ResourcesManager.hpp"


using namespace std;


Material::Material():
m_Texture(0)
{
}


void Material::LoadTexture(std::string Filename)
{
	m_Texture=ResMan.GetTexture(Filename);
	m_TextureFilename=Filename;
}


void Material::Activate()
{
	glEnable(GL_TEXTURE_2D);
	glBindTexture(GL_TEXTURE_2D, m_Texture);
}

void Material::Deactivate()
{
	glBindTexture(GL_TEXTURE_2D, 0);
}